package com.adapter;

/**
 * @ClassName: SquarePeg
 * @Description:
 * @Author Fly
 * @Date 2022/12/19 15:05
 */
public class SquarePeg {

    private double width;// 宽度

    public SquarePeg(double width) {
        this.width = width;
    }

    public double getWidth() {
        return this.width;
    }

    public double getSquare() {
        double result;
        result = Math.pow(this.width, 2);
        return result;
    }
}
